package com.all.play.myapplication.base;

import android.content.Context;
import android.view.View;

/**
 * Created by 聪明一只哈 on 2018/3/28.
 */

public abstract class BasePager {

    public View rootview;
    public Context context;
    //basePager.isInitData防止数据重复初始化
    public boolean isInitData;

    public BasePager(Context context) {
        this.context=context;
        rootview=initView();
    }

    /**
     *初始化视图
     *@author 聪明一只哈
     *@time 2018/3/28 14:20
     */
    public abstract View initView();

    /**
     *加载数据,与视图分离,解耦
     *@author 聪明一只哈
     *@time 2018/3/28 14:21
     */
    public void initData(){

    }
}
